home *** CD-ROM | disk | FTP | other *** search
- Subject: Re: Finding locations of other Frames
- Sent: 4/19/96 1:49 PM
- Received: 4/19/96 2:01 PM
- From: Henri Lamiraux, lamiraux@apple.com
- Reply-To: ODF-Interest@CILabs.ORG
- To: OpenDoc Development Framework Discussion List, ODF-Interest@CILabs.
-
- >Is there anyway to find the location of Frame within a containing frame. It
- >is my impression that I don't really need to do this, however, why give an
- >orgainzational structure (i.e. Embedded Frames have a shape) if you were
- >never meant to use them.
- >
- >I want to know mainly for placing of things, if I create a frame
- >programmatically I want to place it geographically near the some other
- >Frame that is owned by the same part (i.e siblings), and I seem to not
- >quite be understaning if I can even do that. It seems I can make a few
- >assumptions about things once the Facets are created, but nothing
- >beforehand.
- >
- >Is this true?
- >
- >Jer,
- >
- >--------------------------------------------------------------------------
- >----
- >Jerome Jahnke |Well, I was only a kid didn't know enough to be
- >afraid
- >BSD Academic Computing |Playing the game, but not the way the big boys played
- >University of Chicago |Nothing to lose maybe I had something to trade
- >j-jahnke@uchicago.edu |The way the big wheel spins * The Big Wheel -- N
- >Peart
- >----------------------------------------------------------------------------
- >--
- >
-
- The Frame shape does not have any notion of position it only has a notion
- of size. Frame shape should always have their top-left corner equal to
- (0,0). The position is given by the external transform of the facet. So
- yes you are right you can only know the position of a frame once the
- facet is created. But, as an embedding part you should have some data
- structure that tell you where embedded frame are. It is your data
- structure that telling OpenDoc where to create a facet. You should not
- rely on OpenDoc to keep track of the position of your embedded facets.
- Look at ODFDraw, it has a proxyShape which contains the position and size
- of embedded frames (/facets). Embedded frames and facets are created
- using the proxyshape data. At anytime you should be able to tell what is
- the size and position of an embedded frame without even having to a metod
- of ODFrame and ODFacet.
-
- .......................................................................
- Henri Lamiraux lamiraux@apple.com
- Apple Computer, Inc. OpenDoc(tm) Development Framework
- .......................................................................
-
-
-